Image processing device and method

ABSTRACT

In an image processing device capable of collectively estimating an object based upon results of plural times of inspection, regions ( 1 ( 1 )) and ( 1 ( 2 )) to be photographed are defined on opposite end portions of an object (w). When an image of the left end portion of the object (w) is captured in response to a first trigger, the image processing device acquires corresponding image data, and the length (x1) of a projection extending in the x-direction at the left end of the object (w). When an image of the right end portion of the object ( 2 ) is next captured in response to a second trigger, the image processing device captures corresponding image data and measures the length (x2) of a projection extending in the x-direction at the right end of the work (w). Thereafter, the device finds the sum (x1+x2) of the lengths (x1, x2) inside, and outputs a result externally.

BACKGROUND OF THE INVENTION

[0001] 1. Field of the Invention

[0002] This invention relates to an image processing device and method.

[0003] 2. Related Background Art

[0004] Conventional image processing devices are configured to outputthe result of analysis each time after execution of a unit of jobs on animage, namely, acquiring image data on the single image from a camera,processing and inspecting the acquired image data.

[0005] Therefore, as shown in FIG. 1 for example, in case an object of alarge size needs inspection of some portions thereof discrete over aregion beyond the coverage by the field of view of a single camera, itis necessary to use two or more cameras C1, C2 to acquire image data ofsuch portions to be examined from respective cameras.

[0006] However, since any image processing device has only a limitednumber of connectors for cameras, image processing devices of this typecannot cope with inspection of objects requiring more cameras than themaximum number connectable to a single image processing device.

[0007] This inconvenience is overcome if relative movement is possiblebetween one or more cameras and an object to be examined as shown inFIG. 2, for example, in which a single camera C1 is shown as being movedfrom one portion to another. In this case, the image processing devicecan sequentially acquire and inspect images of different positions ofthe object from the camera or cameras in response to triggers generatedinside or introduced from outside in predetermined time intervals.

[0008] Both these methods, however, cannot treat results of inspectionobtained by a plurality of times of inspection of a single object or aplurality of identical objects to collectively estimate the entireacceptability, quality, etc. of the object or identical objects.

SUMMARY OF THE INVENTION

[0009] It is therefore an object of the invention to provide an imageprocessing device and an image processing method capable of collectivelyestimating an object based upon a plurality of times of inspection.

[0010] A further object of the invention is to provide an imageprocessing device and an image processing method capable of collectivelyestimating a large-sized object not covered by the field of view of acamera.

[0011] A still further object of the invention is to provide an imageprocessing device and an image processing method capable of collectivelyestimating a plurality of identical objects.

[0012] In order to achieve the above objects, the invention ischaracterized in executing collective estimation after completing aplurality of times of acquisition of image data from a camera and aplurality of times of image processing of individual pieces of imagedata.

[0013] One camera or a plurality of cameras may be used to obtain imagedata on a plurality of portions of one or more objects to be examined.

BRIEF DESCRIPTION OF THE DRAWINGS

[0014]FIG. 1 is a diagram for explaining a conventional method ofinspection of a relatively large-sized object;

[0015]FIG. 2 is a diagram for explaining another conventional methodcapable of overcoming a disadvantage of the conventional method shown inFIG. 1 in case of inspection of a relatively large-sized object;

[0016]FIG. 3 is a timing chart for explaining procedures in anembodiment of the invention;

[0017]FIG. 4 is a diagram for explaining an example of registration of auser's optional setting according to an embodiment of the invention;

[0018]FIG. 5 is a diagram for explaining that an embodiment of theinvention is effective for collective estimation of a plurality ofidentical objects;

[0019]FIG. 6 is a diagram for explaining that an embodiment of theinvention is effective for collective estimation of a relativelylarge-sized object by different kinds of inspection of differentportions of the object;

[0020]FIG. 7 is a diagram for explaining that an embodiment of theinvention is effective when applied to collective estimation of anelongate object;

[0021]FIG. 8 is a diagram for explaining that an embodiment of theinvention is effective for measuring the sum of lengths x1, x2 ofprojections extending in the x-direction at opposite ends of an object;

[0022]FIG. 9 is a diagram for explaining procedures of operation of animage processing device according to an embodiment of the invention forinspection of the object shown in FIG. 8;

[0023]FIGS. 10A and 10B are diagrams for explaining a process forfinding lengths of projections at opposite ends of the object shown inFIG. 8; and

[0024]FIG. 11 is a flowchart for explaining procedures of operation ofthe image processing device according to the same embodiment.

DETAILED DESCRIPTION OF THE INVENTION

[0025]FIG. 3 is a timing chart showing procedures of photographing anobject twice with a single camera in a method according to an embodimentof the invention. In FIG. 3, TRG shows the timing of inputting triggers,BUSY shows the timing of a unit of jobs in a single inspection task on aset of images of one or more objects, BUSY2 shows the timing ofacquiring image data, and STB shows the timing of outputting a result ofcollective estimation. The camera is driven to obtain the first image inresponse to the first trigger at the timing shown by TRG. Responsively,an image processing device acquires image data of the first image fromthe camera at the timing shown by BUSY2 and carries out inspectionincluding arithmetical operation of the data values. Thereafter, thecamera and/or the object are moved to the next relative position, andthe camera is driven to obtain the second image in response to thesecond trigger at the timing shown by TRG. Responsively, the imageprocessing device acquires the image data of the second image from thecamera at the timing shown by BUSY2 and carries out inspection includingarithmetical operation of the data values. After completion of theinspection of the second image data, the image processing device carriesout collective estimation of the object, based upon the result of thefirst inspection and the result of the second inspection, and outputsthe result of the collective estimation to a display of the imageprocessing device or an external device at the timing shown by STB.Thereafter, the image processing device erases the first and secondimage data, related data values, and so on. In case two cameras areprepared and connected to the image processing device, the first cameramay be used to obtain the first image, and the second camera may be usedto obtain the second image.

[0026] It is desirable to permit users to set any desired number ofshots by the camera, i.e. the number of triggers for the camerato-obtain images. Additionally, it is preferable to permit a user to setany kinds of inspection groups combining conditions or contents ofinspection beforehand, and to assign any desired inspection group to aparticular trigger number. For example, an inspection group GR1 may beassigned to an n-th trigger, and the same inspection group GR1 ordifferent inspection group GR2, for example, may be assigned to the nexttrigger number. Examples of the conditions or contents of inspectioninclude positions of an object or objects to be examined. That is, theterm “inspection group” herein means a combination of inspection itemsfor a single target image. The term “inspection (measurement)” means akind of designated inspection or a set of designated kinds of inspectionto be executed on a pattern formed by one or more windows set on eachtarget image. FIG. 4 shows an example of registration of such user'soptional setting. In FIG. 4, if the number of triggers is 3, inspectionof the first group GR1 is executed in response to the first trigger;inspection of the second group GR2 is executed in response to the secondtrigger; and inspection of the third group GR3 is executed in responseto the third trigger.

[0027]FIG. 5 shows a rather concrete example of inspection. Here iscarried out identical inspection of a plurality of identical objects w,which may be products of a common lot, each having a size fully coveredby the field of view of a camera. In this example, six identical objectsw1 through w6 are shown. After inspection of the final one of theseobjects, results of six times of inspection are collectively estimated,and a result of the collective estimation of all objects is output. InFIG. 5, reference numeral 1 denotes a target image. In the example ofFIG. 5, if these steps and contents of inspection are registered byuser's choice similarly to the user's optional setting of FIG. 4, thenthe number of triggers is 6, and one inspection group is assigned to alltrigger numbers. Thus, all these identical objects w1 through w6 shownin FIG. 5 are examined by identical inspection, and are collectivelyestimated from results of six times of identical inspection.

[0028]FIG. 6 shows another example of inspection. Here is carried outdifferent kinds of inspection of a relatively large-sized single objectw having a plurality of portions to be examined, which are not coveredentirely by the field of view of a camera. Different target images 1(1)through 1(6) of the object w are prepared, and corresponding image dataundergo different items of inspection. After the inspection of imagedata on the target image 1(6) to be finally inspected, a result ofcollective estimation of the object w is output. If these steps andcontents of inspection are registered by user's choice similarly to theuser's optional setting of FIG. 4, the number of triggers is 6, anddifferent inspection groups are assigned to the respective triggernumbers. Thus, the object can be examined by different kinds ofinspection, and can be collectively estimated from results of six timesof different kinds of inspection.

[0029]FIG. 7 shows another example of inspection. Here is taken anelongate single object w like a cable having a plurality of portions tobe examined, which are not covered entirely by the field of view of acamera. The elongate object w is photographed a plurality of times whileit moves aside a stationary camera. After inspection of a portion of theobject w to be finally inspected for example, a result of collectiveestimation of the elongate object w is output. If these steps andcontents of inspection are registered by user's choice similarly to theuser's optional setting of FIG. 4, one inspection group (identicalinspection) is assigned to respective trigger numbers of the triggersdetermined by the user. Thus, a plurality of timed of the inspection andthe collective estimation can be carried out as explained above.

[0030] Next referring to FIGS. 8 through 11, inspection or measurementby internal processing of an image processing device according to anembodiment will be explained below. Here is shown a process for findingthe sum of lengths x1, x2 of projections extending at opposite ends of arelatively long object w shown in FIG. 8, and outputting its result.

[0031] As shown in FIG. 9, target images 1(1) and 1(2) of opposite endportions of the object w are prepared. A single camera may be used forobtaining required images of the object w, and either the camera or theobject w may be moved to required relative positions.

[0032] In response to a first trigger, the camera is driven to obtain afirst image of the left end portion of the object w including the leftprojection, which is the first target image 1(1). Responsively, theimage processing device acquires image data of the first target image.Thereafter, the image processing device measures the length x1 of theleft projection extending in the x-direction at the left end of theobject w as shown in FIG. 10A. In the next process, the camera is drivenby a second trigger to capture a second image of the right end portionof the object w including the right projection, which is the secondtarget image 1(2). Responsively, the image processing device acquiresimage data of the second image data 1(2). Thereafter, the imageprocessing device measures the length x2 of the right projectionextending in the x-direction at the right end of the object w as shownin FIG. 10B. After that, the image processing device totals x1 and x2and obtains the value (x1+x2) inside.

[0033] With reference to FIG. 11, procedures of operation of the imageprocessing device are explained in greater detail. In step S1, a userregisters the optional setting of a necessary number of shots by thecamera (number of triggers) and other required conditions forinspection, as already explained with reference to FIG. 4. That is, theuser registers “2” as the number of triggers; assigns “GR1” to the firsttrigger and “GR2” to the second trigger; and designates “Inspection1+Inspection 2” as the arithmetical operation.

[0034] In the next step S2, the object w or the camera is moved to apredetermined relative position to focus the camera onto the left endportion of the object 2. In the next step S3, the camera captures thefirst image of the left end portion of the object w, and the imageprocessing device acquires image data of the first image. In the nextstep S4, the image processing device measures the length x1 of the leftprojection of the object w. In the next step 5, the device confirmswhether the number of triggers has reached 2 or not, and returns to stepS2 because the number of triggers is still 1. Thereafter, the steps S2to S4 are repeated to establish relative positional relation between theobject 2 and the camera for focusing the camera onto the right endportion of the object 2; drive the camera to capture the second image ofthe right end portion of the work; acquire the image data of the secondtarget image from the camera; and measures the length X2 of the rightprojection of the object w.

[0035] After completion of the second measurement, the image processingdevice proceeds to the step S5 and further to the step S6, andcalculates the final output value (Out) by addition of the lengths x1and x2. Additionally, it compares the final output (Out) with apredetermined allowance (having the upper limit Max(Out) and the lowerlimit of Min(Out)).

[0036] That is, if the final output value satisfiesMin(Out)≦Out≦Max(Out), the image processing device estimates that theobject w is acceptable, and if the final output (Out) is not within theallowance, that is, if Out≦Min(Out) or Max(Out)≦Out, it estimates thatthe object w is not acceptable. After the estimation, the device outputsa result of estimation to a display of the device itself or an externaldevice in step S8.

What is claimed is:
 1. An image processing device for inspection byimage processing of image data acquired from a camera which capturesimages of at least one object, comprising: shot number setting means forsetting the number of shots of photographing of the object with thecamera; preliminary inspection means for sequentially inspecting theimage data acquired from the camera by image processing each time whenthe camera captures an image of the object until the number of shotsreaches the value set by the shot number setting means; collectiveestimation means for collectively estimating the object on the basis ofresults of inspection of image data of the individual images afterinspection of image data of the image captured by final one of the shotsdetermined by the shot number setting means; and output means foroutputting a result of collective estimation by the collectiveestimation means.
 2. The image processing means according to claim 1wherein the preliminary inspection means carries out identicalinspection upon any of the shots determined beforehand.
 3. The imageprocessing means according to claim 1 wherein the preliminary inspectionmeans carries out different kinds of inspection inspects for therespective shots determined beforehand.
 4. The image processing meansaccording to claim 1 further comprising an inspection item setting meansfor setting at least one inspection item in association with individualsaid shots for the inspection by the preliminary inspection means. 5.The image processing means according to claim 1 further comprising adata erasure means for erasing the image data acquired from the camera,results of inspection by the preliminary inspection means and the resultof collective estimation after the output means outputs the result ofthe collective estimation of the object.
 6. An image processing methodcomprising: a preliminary inspection step for acquiring image data froma camera, carrying out image processing of the acquired image data andexecuting predetermined items of inspection each time when the cameracaptures an image of an object, and repeating these procedurespredetermined times; a collective inspection step for collectivelyinspecting the object on the basis of results obtained by a plurality ofoccurrences of the preliminary inspection step; and a collective resultoutputting step for outputting a result obtained in the collectiveinspection step.
 7. The image processing method according to claim 6further comprising a data erasing step for erasing the image data of theobject, results of preliminary inspection obtained by a plurality ofoccurrences of the preliminary inspection step and the result ofcollective estimation obtained in the collective inspection step afterthe collective result outputting step.
 8. The image processing methodaccording to claim 7 wherein the images are captured by the camera froma plurality of identical objects contained in a single box, all of theobjects are inspected by an identical item of inspection in any event ofthe preliminary inspection step.
 9. The image processing methodaccording to claim 7 wherein the images are captured by the camera fromdifferent portions of a single object, and the different portions of thesingle object are inspected in a plurality of events of the preliminaryinspection step, respectively. 10 The image processing method accordingto claim 7 wherein the object is an elongate single object having firstand second ends, and the first and second ends of the object areinspected in respective occurrences of the preliminary inspection step.11. The image processing method according to claim 10 wherein thecollective inspection step executes inspection of an error of thelengthwise size of the elongate object based upon the inspection of thefirst end second ends thereof in the preliminary inspection step.